<!DOCTYPE html>
<html lang="en-us">
<head>
    <title>Cowboy Programmer</title>
    <meta name="generator" content="Hugo 0.30.2" />
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="author" content="Space Cowboy">
    
      <meta name="description" content="">
    
    <link rel="alternate" type="application/rss" href="https://cowboyprogrammer.org/index.xml">
    <link rel="alternate" type="application/json" href="https://cowboyprogrammer.org/feed.json">
    <link rel="alternate" type="application/atom" href="https://cowboyprogrammer.org/atom.xml">
    <link rel="canonical" href="https://cowboyprogrammer.org/"/>
    <link rel="icon" href="https://cowboyprogrammer.org/favicon.ico">
    <link rel="apple-touch-icon" href="https://cowboyprogrammer.org/apple-touch-icon.png" />
    <link rel="stylesheet" href="https://cowboyprogrammer.org/css/style.css">
    <link rel="stylesheet" href="https://cowboyprogrammer.org/css/hack.min.css">
    <link rel="stylesheet" href="https://cowboyprogrammer.org/css/font-awesome.min.css">
    <link href='https://fonts.googleapis.com/css?family=Roboto:400,700,400italic' rel='stylesheet' type='text/css'>
    <meta property="og:title" content="Cowboy Programmer" />
<meta property="og:description" content="" />
<meta property="og:type" content="website" />
<meta property="og:url" content="https://cowboyprogrammer.org/" />



<meta property="og:updated_time" content="2016-10-21T00:27:00&#43;02:00"/>










    
    
<meta itemprop="name" content="Cowboy Programmer">
<meta itemprop="description" content="">


    <meta name="twitter:card" content="summary"/><meta name="twitter:title" content="Cowboy Programmer"/>
<meta name="twitter:description" content=""/>

    

    
</head>
<body>
<div class="container">


<div id="container">
    <header id="header">
  <div id="header-main" class="header-inner">
    <div class="outer">
      <a href="https://cowboyprogrammer.org/" id="logo">
          
          <i class="logo" style="background-image: url('https://cowboyprogrammer.org/css/images/logo.png')"></i>
          
          <span class="site-title">Cowboy Programmer</span>
      </a>
      <nav id="main-nav">
          
          
          <a class="main-nav-link" href="https://cowboyprogrammer.org/">Home</a>
          
          
          
          

          

          
          
          
          
          <a class="main-nav-link" href="https://cowboyprogrammer.org/tags/">Tags</a>
          
          
      </nav>
      <div id="search-form-wrap">
        <form action="/search" method="get" accept-charset="UTF-8" class="search-form">
          <input type="search" name="q" results="0" class="search-form-input" placeholder="Search">
          <button type="submit" class="search-form-submit">
          </button>
        </form>
      </div>
    </div>
  </div>
  <div id="main-nav-mobile" class="header-sub header-inner">
    <table class="menu outer">
      <tbody>
          <tr>
          
          
          <td><a class="main-nav-link" href="https://cowboyprogrammer.org/">Home</a></td>
          
          
          
          

          

          
          
          
          
          <td><a class="main-nav-link" href="https://cowboyprogrammer.org/tags/">Tags</a></td>
          
          
          <td>
          <form action="/search" method="get" accept-charset="UTF-8" class="search-form">
            <input type="search" name="q" results="0" class="search-form-input" placeholder="Search">
         </form>
        </td>
      </tr>
      </tbody>
    </table>
  </div>
</header>


    <div class="outer">
    <aside id="profile">
  <div class="inner profile-inner">
    <div class="base-info profile-block">
      <img id="avatar" src="https://cowboyprogrammer.org/css/images/avatar.png">
      <h2 id="name">Space Cowboy</h2>
      <h3 id="title">Virtual prepper</h3>
      
      
          <a id="follow" href="https://github.com/spacecowboy">
              Follow
          </a>
      
    </div>
    <div class="article-info profile-block">
      <div class="article-info-block">
        24
        <span>Posts</span>
      </div>
      <div class="article-info-block">
        
          39
        
        <span>
            Tags
        </span>
      </div>
    </div>
    <div class="contact-info profile-block">
      <table class="contact-list">
        <tr>
          
<td><a href="//github.com/spacecowboy" target="_blank" title="GitHub"><i class="fa fa-github"></i></a></td>










































<td><a href="//stackoverflow.com/users/535073/jonas-kalderstam" target="_blank" title="Stack Overflow"><i class="fa fa-stack-overflow"></i></a></td>












          <td><a href="https://cowboyprogrammer.org/atom.xml" target="_blank" title="Feed"><i class="fa fa-rss"></i></a></td>
        </tr>
      </table>
    </div>
  </div>
</aside>

    <section id="main">
    
    
    <article class="article article-type-post" itemscope="" itemprop="blogPost">
        <div class="article-inner">
            
            <a href="https://cowboyprogrammer.org/2016/10/reduce-colors-in-images/" itemprop="url">
                <img src="https://cowboyprogrammer.org/images/2017/10/gimp_image_mode_index.png" class="article-banner">
            
            </a>

            <header class="article-header">
    <a href="https://cowboyprogrammer.org/2016/10/reduce-colors-in-images/">
    <h1 class="article-title" itemprop="name">
        Reduce the size of images even further by reducing number of colors with Gimp
    </h1>
    </a>
    <div class="article-meta">
        <div class="article-date">
            <i class="fa fa-calendar"></i>
            <time datetime="2016-10-21 00:27:00 &#43;0200 CEST" itemprop="datePublished">2016-10-21</time>
            &middot;
            289
            words
            &middot;
            2
            minute read
        </div>

        
        
            
            
        

        
            
            
            <div class="article-category">
                <i class="fa fa-tags"></i>
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/zopfli">zopfli</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/gimp">gimp</a>
                
                
            </div>
            
        
    </div>
</header>

            <div class="article-entry" itemprop="articleBody">
                <p>
                    In Gimp you go to Image in the top menu bar and select Mode followed by Indexed. Now you see a popup where you can select the number of colors for a generated optimum palette.
You&rsquo;ll have to experiment a little because it will depend on your image.
I used this approach to shrink the size of the cover image in the_zopfli post from a 37KB (JPG) to just 15KB (PNG, all PNG sizes listed include Zopfli compression btw).
                    <br>
                </p>
                <p class="article-more-link">
                    <a href="https://cowboyprogrammer.org/2016/10/reduce-colors-in-images/">
                        Read more
                    </a>
                </p>
            </div>
            

        </div>
    </article>
    
    <article class="article article-type-post" itemscope="" itemprop="blogPost">
        <div class="article-inner">
            
            <a href="https://cowboyprogrammer.org/2016/10/dont-start-service-on-install-of-debian-package/" itemprop="url">
                <img src="https://cowboyprogrammer.org/images/Ardebian_logo_512_0.png" class="article-banner">
            
            </a>

            <header class="article-header">
    <a href="https://cowboyprogrammer.org/2016/10/dont-start-service-on-install-of-debian-package/">
    <h1 class="article-title" itemprop="name">
        Don&#39;t start service on installation of Debian package
    </h1>
    </a>
    <div class="article-meta">
        <div class="article-date">
            <i class="fa fa-calendar"></i>
            <time datetime="2016-10-19 00:00:00 &#43;0200 CEST" itemprop="datePublished">2016-10-19</time>
            &middot;
            113
            words
            &middot;
            1
            minute read
        </div>

        
        

        
            
            
            <div class="article-category">
                <i class="fa fa-tags"></i>
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/linux">linux</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/debian">debian</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/ubuntu">ubuntu</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/systemd">systemd</a>
                
                
            </div>
            
        
    </div>
</header>

            <div class="article-entry" itemprop="articleBody">
                <p>
                    A clear difference between Debian/Ubuntu and for example Red Hat/Fedora is that packages which include system services will enable and start those services at install time in Debian/Ubuntu whereas they will not start automatically in Red Hat/Fedora.
Sometimes it would be very convenient if the service would not start automatically, for example if you need to configure the service before starting it for the first time.
To prevent the automatic start of system services at install time in Debian, just set the RUNLEVEL environment variable like so:
                    <br>
                </p>
                <p class="article-more-link">
                    <a href="https://cowboyprogrammer.org/2016/10/dont-start-service-on-install-of-debian-package/">
                        Read more
                    </a>
                </p>
            </div>
            

        </div>
    </article>
    
    <article class="article article-type-post" itemscope="" itemprop="blogPost">
        <div class="article-inner">
            
            </a>

            <header class="article-header">
    <a href="https://cowboyprogrammer.org/2016/09/reboot_machine_on_wrong_password/">
    <h1 class="article-title" itemprop="name">
        Rebooting on wrong password
    </h1>
    </a>
    <div class="article-meta">
        <div class="article-date">
            <i class="fa fa-calendar"></i>
            <time datetime="2016-09-28 22:57:21 &#43;0200 CEST" itemprop="datePublished">2016-09-28</time>
            &middot;
            483
            words
            &middot;
            3
            minute read
        </div>

        
        
            
            
        

        
            
            
            <div class="article-category">
                <i class="fa fa-tags"></i>
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/linux">linux</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/computers">computers</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/encryption">encryption</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/security">security</a>
                
                
            </div>
            
        
    </div>
</header>

            <div class="article-entry" itemprop="articleBody">
                <p>
                    Having an encrypted hard drive is all well and good, but chances are that if someone is gonna steal your laptop, it&rsquo;s probably not going to be turned off. Most likely, it will be stolen in a powered-on state. And so your encrypted hard drive doesn&rsquo;t increase your security at all since it&rsquo;s currently unlocked.
In my mind, it&rsquo;s a slight improvement if the computer somehow can shutdown if someone is trying to gain access to it.
                    <br>
                </p>
                <p class="article-more-link">
                    <a href="https://cowboyprogrammer.org/2016/09/reboot_machine_on_wrong_password/">
                        Read more
                    </a>
                </p>
            </div>
            

        </div>
    </article>
    
    <article class="article article-type-post" itemscope="" itemprop="blogPost">
        <div class="article-inner">
            
            <a href="https://cowboyprogrammer.org/2016/08/zopfli_all_the_things/" itemprop="url">
                <img src="https://cowboyprogrammer.org/images/2017/10/zopfli_all_the_things_32.png" class="article-banner">
            
            </a>

            <header class="article-header">
    <a href="https://cowboyprogrammer.org/2016/08/zopfli_all_the_things/">
    <h1 class="article-title" itemprop="name">
        Compress all the images!
    </h1>
    </a>
    <div class="article-meta">
        <div class="article-date">
            <i class="fa fa-calendar"></i>
            <time datetime="2016-08-26 13:17:40 &#43;0200 CEST" itemprop="datePublished">2016-08-26</time>
            &middot;
            740
            words
            &middot;
            4
            minute read
        </div>

        
        
            
            
        

        
            
            
            <div class="article-category">
                <i class="fa fa-tags"></i>
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/hugo">hugo</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/zopfli">zopfli</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/make">make</a>
                
                
            </div>
            
        
    </div>
</header>

            <div class="article-entry" itemprop="articleBody">
                <p>
                    Update 2016-11-22: Made the Makefile compatible with BSD sed (MacOS)
One advantage that static sites, such as those built by Hugo, provide is fast loading times. Because there is no processing to be done, no server side rendering, no database lookups, loading times are just as fast as you can serve the files that make up the page. This means that bandwidth becomes the primary bottleneck, which incidentally is one of the factors used by Google to calculate your search ranking.
                    <br>
                </p>
                <p class="article-more-link">
                    <a href="https://cowboyprogrammer.org/2016/08/zopfli_all_the_things/">
                        Read more
                    </a>
                </p>
            </div>
            

        </div>
    </article>
    
    <article class="article article-type-post" itemscope="" itemprop="blogPost">
        <div class="article-inner">
            
            <a href="https://cowboyprogrammer.org/2016/07/migrating_from_ghost_to_hugo/" itemprop="url">
                <img src="https://cowboyprogrammer.org/images/hugo-logo.png" class="article-banner">
            
            </a>

            <header class="article-header">
    <a href="https://cowboyprogrammer.org/2016/07/migrating_from_ghost_to_hugo/">
    <h1 class="article-title" itemprop="name">
        Migrating from Ghost to Hugo
    </h1>
    </a>
    <div class="article-meta">
        <div class="article-date">
            <i class="fa fa-calendar"></i>
            <time datetime="2016-07-25 23:55:38 &#43;0200 CEST" itemprop="datePublished">2016-07-25</time>
            &middot;
            1013
            words
            &middot;
            5
            minute read
        </div>

        
        
            
            
        

        
            
            
            <div class="article-category">
                <i class="fa fa-tags"></i>
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/ghost">ghost</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/hugo">Hugo</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/python">python</a>
                &middot;
                
                <a class="article-category-link" href="https://cowboyprogrammer.org/tags/programming">programming</a>
                
                
            </div>
            
        
    </div>
</header>

            <div class="article-entry" itemprop="articleBody">
                <p>
                    So I recently migrated this site from Ghost to Hugo after reading a nice article about the Hugo in Linux Voice #20 (funnily enough, the same issue also features an article about Ghost). I originally made the switch to Ghost from Jekyll back in 2014 or so mainly because I could not find a good theme to use. Ghost also seemed to have a lot of cool features and it&rsquo;s fun to try new things.
                    <br>
                </p>
                <p class="article-more-link">
                    <a href="https://cowboyprogrammer.org/2016/07/migrating_from_ghost_to_hugo/">
                        Read more
                    </a>
                </p>
            </div>
            

        </div>
    </article>
    

    <nav id="page-nav">

    
    
        <a class="extend next" rel="next" href="https://cowboyprogrammer.org//page/2/">
            Next »
        </a>
    

</nav>

</section>


    <aside id="sidebar">
    
<div class="widget-wrap">
    <h3 class="widget-title">
        Recents
    </h3>
    <div class="widget">
        <ul id="recent-post">
            
            <li>
                <div class="item-thumbnail">
                    <a href="https://cowboyprogrammer.org/2016/10/reduce-colors-in-images/" class="thumbnail">
                    
                        <span style="background-image:url(https://cowboyprogrammer.org/images/2017/10/gimp_image_mode_index.png)" alt="Cowboy Programmer" class="thumbnail-image"></span>
                    
                    </a>
                </div>
                <div class="item-inner">
                    
                    
                    
                    <p class="item-title"><a href="https://cowboyprogrammer.org/2016/10/reduce-colors-in-images/" class="title">Reduce the size of images even further by reducing number of colors with Gimp</a></p>
                    <p class="item-date">
                        <time datetime="2016-10-21 00:27:00 &#43;0200 CEST" itemprop="datePublished">2016-10-21</time>
                    </p>
                </div>
            </li>
            
            <li>
                <div class="item-thumbnail">
                    <a href="https://cowboyprogrammer.org/2016/10/dont-start-service-on-install-of-debian-package/" class="thumbnail">
                    
                        <span style="background-image:url(https://cowboyprogrammer.org/images/Ardebian_logo_512_0.png)" alt="Cowboy Programmer" class="thumbnail-image"></span>
                    
                    </a>
                </div>
                <div class="item-inner">
                    
                    <p class="item-title"><a href="https://cowboyprogrammer.org/2016/10/dont-start-service-on-install-of-debian-package/" class="title">Don&#39;t start service on installation of Debian package</a></p>
                    <p class="item-date">
                        <time datetime="2016-10-19 00:00:00 &#43;0200 CEST" itemprop="datePublished">2016-10-19</time>
                    </p>
                </div>
            </li>
            
            <li>
                <div class="item-thumbnail">
                    <a href="https://cowboyprogrammer.org/2016/09/reboot_machine_on_wrong_password/" class="thumbnail">
                    
                        <span class="thumbnail-image thumbnail-none"></span>
                    
                    </a>
                </div>
                <div class="item-inner">
                    
                    
                    
                    <p class="item-title"><a href="https://cowboyprogrammer.org/2016/09/reboot_machine_on_wrong_password/" class="title">Rebooting on wrong password</a></p>
                    <p class="item-date">
                        <time datetime="2016-09-28 22:57:21 &#43;0200 CEST" itemprop="datePublished">2016-09-28</time>
                    </p>
                </div>
            </li>
            
            <li>
                <div class="item-thumbnail">
                    <a href="https://cowboyprogrammer.org/2016/08/zopfli_all_the_things/" class="thumbnail">
                    
                        <span style="background-image:url(https://cowboyprogrammer.org/images/2017/10/zopfli_all_the_things_32.png)" alt="Cowboy Programmer" class="thumbnail-image"></span>
                    
                    </a>
                </div>
                <div class="item-inner">
                    
                    
                    
                    <p class="item-title"><a href="https://cowboyprogrammer.org/2016/08/zopfli_all_the_things/" class="title">Compress all the images!</a></p>
                    <p class="item-date">
                        <time datetime="2016-08-26 13:17:40 &#43;0200 CEST" itemprop="datePublished">2016-08-26</time>
                    </p>
                </div>
            </li>
            
            <li>
                <div class="item-thumbnail">
                    <a href="https://cowboyprogrammer.org/2016/07/migrating_from_ghost_to_hugo/" class="thumbnail">
                    
                        <span style="background-image:url(https://cowboyprogrammer.org/images/hugo-logo.png)" alt="Cowboy Programmer" class="thumbnail-image"></span>
                    
                    </a>
                </div>
                <div class="item-inner">
                    
                    
                    
                    <p class="item-title"><a href="https://cowboyprogrammer.org/2016/07/migrating_from_ghost_to_hugo/" class="title">Migrating from Ghost to Hugo</a></p>
                    <p class="item-date">
                        <time datetime="2016-07-25 23:55:38 &#43;0200 CEST" itemprop="datePublished">2016-07-25</time>
                    </p>
                </div>
            </li>
            
        </ul>
    </div>
</div>


    
    
    


<div class="widget-wrap">
    <h3 class="widget-title">
        Tag cloud
    </h3>
    <div class="widget tagcloud">
        
        <a href="https://cowboyprogrammer.org/tags/adblock" style="font-size: 12px;">adblock</a>
        
        <a href="https://cowboyprogrammer.org/tags/advertising" style="font-size: 12px;">advertising</a>
        
        <a href="https://cowboyprogrammer.org/tags/android" style="font-size: 12px;">android</a>
        
        <a href="https://cowboyprogrammer.org/tags/apple" style="font-size: 12px;">apple</a>
        
        <a href="https://cowboyprogrammer.org/tags/btrfs" style="font-size: 12px;">btrfs</a>
        
        <a href="https://cowboyprogrammer.org/tags/c/c&#43;&#43;" style="font-size: 12px;">c/c&#43;&#43;</a>
        
        <a href="https://cowboyprogrammer.org/tags/command-line" style="font-size: 12px;">command-line</a>
        
        <a href="https://cowboyprogrammer.org/tags/computers" style="font-size: 12px;">computers</a>
        
        <a href="https://cowboyprogrammer.org/tags/conkeror" style="font-size: 12px;">conkeror</a>
        
        <a href="https://cowboyprogrammer.org/tags/css" style="font-size: 12px;">css</a>
        
        <a href="https://cowboyprogrammer.org/tags/dark" style="font-size: 12px;">dark</a>
        
        <a href="https://cowboyprogrammer.org/tags/debian" style="font-size: 12px;">debian</a>
        
        <a href="https://cowboyprogrammer.org/tags/encryption" style="font-size: 12px;">encryption</a>
        
        <a href="https://cowboyprogrammer.org/tags/fortran" style="font-size: 12px;">fortran</a>
        
        <a href="https://cowboyprogrammer.org/tags/gaming" style="font-size: 12px;">gaming</a>
        
        <a href="https://cowboyprogrammer.org/tags/ghost" style="font-size: 12px;">ghost</a>
        
        <a href="https://cowboyprogrammer.org/tags/gimp" style="font-size: 12px;">gimp</a>
        
        <a href="https://cowboyprogrammer.org/tags/gradle" style="font-size: 12px;">gradle</a>
        
        <a href="https://cowboyprogrammer.org/tags/hugo" style="font-size: 12px;">hugo</a>
        
        <a href="https://cowboyprogrammer.org/tags/ios" style="font-size: 12px;">ios</a>
        
        <a href="https://cowboyprogrammer.org/tags/jenkins" style="font-size: 12px;">jenkins</a>
        
        <a href="https://cowboyprogrammer.org/tags/linux" style="font-size: 12px;">linux</a>
        
        <a href="https://cowboyprogrammer.org/tags/make" style="font-size: 12px;">make</a>
        
        <a href="https://cowboyprogrammer.org/tags/malware" style="font-size: 12px;">malware</a>
        
        <a href="https://cowboyprogrammer.org/tags/microsoft" style="font-size: 12px;">microsoft</a>
        
        <a href="https://cowboyprogrammer.org/tags/nononsenseapps" style="font-size: 12px;">nononsenseapps</a>
        
        <a href="https://cowboyprogrammer.org/tags/nononsensenotes" style="font-size: 12px;">nononsensenotes</a>
        
        <a href="https://cowboyprogrammer.org/tags/org" style="font-size: 12px;">org</a>
        
        <a href="https://cowboyprogrammer.org/tags/os-x" style="font-size: 12px;">os-x</a>
        
        <a href="https://cowboyprogrammer.org/tags/programming" style="font-size: 12px;">programming</a>
        
        <a href="https://cowboyprogrammer.org/tags/python" style="font-size: 12px;">python</a>
        
        <a href="https://cowboyprogrammer.org/tags/security" style="font-size: 12px;">security</a>
        
        <a href="https://cowboyprogrammer.org/tags/systemd" style="font-size: 12px;">systemd</a>
        
        <a href="https://cowboyprogrammer.org/tags/tutorials" style="font-size: 12px;">tutorials</a>
        
        <a href="https://cowboyprogrammer.org/tags/ubuntu" style="font-size: 12px;">ubuntu</a>
        
        <a href="https://cowboyprogrammer.org/tags/virus" style="font-size: 12px;">virus</a>
        
        <a href="https://cowboyprogrammer.org/tags/web" style="font-size: 12px;">web</a>
        
        <a href="https://cowboyprogrammer.org/tags/windows" style="font-size: 12px;">windows</a>
        
        <a href="https://cowboyprogrammer.org/tags/zopfli" style="font-size: 12px;">zopfli</a>
        
    </div>
</div>



</aside>

    </div>
</div>

<footer id="footer">
  <div class="outer">
    <div id="footer-info" class="inner">
      &copy; 2017
      Powered by <a href="//gohugo.io">Hugo</a> and <a href="http://themes.gohugo.io/theme/hugo-icarus/">Icarus Theme</a>.
    </div>
  </div>
</footer>



<!-- MathJax -->
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
  tex2jax: {
    inlineMath: [['$','$'], ['\\(','\\)']]}
  });
</script>
<script async src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>



</body>
</html>
